var dbConfig = require('../util/dbconfig')


// 获取文章内容
getWebsite = (req, res) => {
    var sql = "select * from website";
    var sqlArr = [];
    var callBack = (err, data) => {
        if (err) {
            res.send({
                code: 400,
                msg:'获取出错！',
                'list': data
            })
        } else {
            res.send({
                code: 200,
                msg:'success',
                'list': data,
            })
        }
    }
    dbConfig.sqlConnect(sql, sqlArr, callBack);
}
 
module.exports = {
    getWebsite
} 